﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;

namespace HomeBudget
{
    public static class Renderer
    {
        public static void WriteInformation(ListBox listBox, List<Money> items)
        {
            List<string> itemsString = new List<string>();

            foreach (var expense in items)
            {
                itemsString.Add(expense.ToString());
            }

            listBox.ItemsSource = itemsString;
        }
        public static void MoneyNow(TextBlock textBlock, MoneySystem moneySystem)
        {
            textBlock.Text = String.Format("{0}", moneySystem.CalculateMoneyNow());
        }
    }
}
